using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;using Maxleaf.EDI.Domain.K3;

namespace Maxleaf.EDI.DataAccess.K3
{
    public class T_BaseDataDeletedMap : EntityTypeConfiguration<T_BaseDataDeleted>
    {
        public T_BaseDataDeletedMap()
        {
            // Primary Key
            this.HasKey(t => t.FID);

            // Properties
            this.Property(t => t.FTableName)
                .IsRequired()
                .IsFixedLength()
                .HasMaxLength(50);

            this.Property(t => t.FDeletedID)
                .IsRequired()
                .IsFixedLength()
                .HasMaxLength(50);

            this.Property(t => t.FModifyTime)
                .IsRequired()
                .IsFixedLength()
                .HasMaxLength(8)
                .IsRowVersion();

            // Table & Column Mappings
            this.ToTable("T_BaseDataDeleted");
            this.Property(t => t.FID).HasColumnName("FID");
            this.Property(t => t.FTableName).HasColumnName("FTableName");
            this.Property(t => t.FItemClassID).HasColumnName("FItemClassID");
            this.Property(t => t.FDeletedID).HasColumnName("FDeletedID");
            this.Property(t => t.FDeletedUUID).HasColumnName("FDeletedUUID");
            this.Property(t => t.FModifyTime).HasColumnName("FModifyTime");
        }
    }
}
